Optimal. Leaf size=107 \[ \frac {d}{\left (b^2 c^2-a^2 d^2\right ) (c+d x)}-\frac {b \log (a-b x)}{2 a (b c+a d)^2}+\frac {b \log (a+b x)}{2 a (b c-a d)^2}-\frac {2 b^2 c d \log (c+d x)}{\left (b^2 c^2-a^2 d^2\right )^2} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.06, antiderivative size = 107, normalized size of antiderivative = 1.00, number of steps
used = 2, number of rules used = 1, integrand size = 23, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.043, Rules used = {84}
\begin {gather*} \frac {d}{(c+d x) \left (b^2 c^2-a^2 d^2\right )}-\frac {2 b^2 c d \log (c+d x)}{\left (b^2 c^2-a^2 d^2\right )^2}-\frac {b \log (a-b x)}{2 a (a d+b c)^2}+\frac {b \log (a+b x)}{2 a (b c-a d)^2} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 84
Rubi steps
\begin {align*} \int \frac {1}{(a-b x) (a+b x) (c+d x)^2} \, dx &=\int \left (\frac {b^2}{2 a (b c+a d)^2 (a-b x)}+\frac {b^2}{2 a (-b c+a d)^2 (a+b x)}-\frac {d^2}{\left (b^2 c^2-a^2 d^2\right ) (c+d x)^2}-\frac {2 b^2 c d^2}{\left (b^2 c^2-a^2 d^2\right )^2 (c+d x)}\right ) \, dx\\ &=\frac {d}{\left (b^2 c^2-a^2 d^2\right ) (c+d x)}-\frac {b \log (a-b x)}{2 a (b c+a d)^2}+\frac {b \log (a+b x)}{2 a (b c-a d)^2}-\frac {2 b^2 c d \log (c+d x)}{\left (b^2 c^2-a^2 d^2\right )^2}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.15, size = 102, normalized size = 0.95 \begin {gather*} \frac {1}{2} \left (-\frac {b \log (a-b x)}{a (b c+a d)^2}+\frac {\frac {b \log (a+b x)}{a}-\frac {2 d \left (-b^2 c^2+a^2 d^2+2 b^2 c (c+d x) \log (c+d x)\right )}{(b c+a d)^2 (c+d x)}}{(b c-a d)^2}\right ) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A]
time = 0.13, size = 107, normalized size = 1.00
method | result | size |
default | \(-\frac {b \ln \left (-b x +a \right )}{2 a \left (a d +b c \right )^{2}}+\frac {b \ln \left (b x +a \right )}{2 a \left (a d -b c \right )^{2}}-\frac {d}{\left (a d +b c \right ) \left (a d -b c \right ) \left (d x +c \right )}-\frac {2 d \,b^{2} c \ln \left (d x +c \right )}{\left (a d +b c \right )^{2} \left (a d -b c \right )^{2}}\) | \(107\) |
risch | \(-\frac {d}{\left (a^{2} d^{2}-b^{2} c^{2}\right ) \left (d x +c \right )}-\frac {2 b^{2} c d \ln \left (-d x -c \right )}{a^{4} d^{4}-2 a^{2} b^{2} c^{2} d^{2}+b^{4} c^{4}}+\frac {b \ln \left (b x +a \right )}{2 \left (a^{2} d^{2}-2 a b c d +b^{2} c^{2}\right ) a}-\frac {b \ln \left (b x -a \right )}{2 \left (a^{2} d^{2}+2 a b c d +b^{2} c^{2}\right ) a}\) | \(149\) |
norman | \(\frac {d^{2} x}{c \left (a^{2} d^{2}-b^{2} c^{2}\right ) \left (d x +c \right )}+\frac {b \ln \left (b x +a \right )}{2 \left (a^{2} d^{2}-2 a b c d +b^{2} c^{2}\right ) a}-\frac {b \ln \left (-b x +a \right )}{2 \left (a^{2} d^{2}+2 a b c d +b^{2} c^{2}\right ) a}-\frac {2 b^{2} c d \ln \left (d x +c \right )}{a^{4} d^{4}-2 a^{2} b^{2} c^{2} d^{2}+b^{4} c^{4}}\) | \(150\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A]
time = 0.37, size = 157, normalized size = 1.47 \begin {gather*} -\frac {2 \, b^{2} c d \log \left (d x + c\right )}{b^{4} c^{4} - 2 \, a^{2} b^{2} c^{2} d^{2} + a^{4} d^{4}} + \frac {b \log \left (b x + a\right )}{2 \, {\left (a b^{2} c^{2} - 2 \, a^{2} b c d + a^{3} d^{2}\right )}} - \frac {b \log \left (b x - a\right )}{2 \, {\left (a b^{2} c^{2} + 2 \, a^{2} b c d + a^{3} d^{2}\right )}} + \frac {d}{b^{2} c^{3} - a^{2} c d^{2} + {\left (b^{2} c^{2} d - a^{2} d^{3}\right )} x} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [B] Leaf count of result is larger than twice the leaf count of optimal. 244 vs.
\(2 (103) = 206\).
time = 2.05, size = 244, normalized size = 2.28 \begin {gather*} \frac {2 \, a b^{2} c^{2} d - 2 \, a^{3} d^{3} + {\left (b^{3} c^{3} + 2 \, a b^{2} c^{2} d + a^{2} b c d^{2} + {\left (b^{3} c^{2} d + 2 \, a b^{2} c d^{2} + a^{2} b d^{3}\right )} x\right )} \log \left (b x + a\right ) - {\left (b^{3} c^{3} - 2 \, a b^{2} c^{2} d + a^{2} b c d^{2} + {\left (b^{3} c^{2} d - 2 \, a b^{2} c d^{2} + a^{2} b d^{3}\right )} x\right )} \log \left (b x - a\right ) - 4 \, {\left (a b^{2} c d^{2} x + a b^{2} c^{2} d\right )} \log \left (d x + c\right )}{2 \, {\left (a b^{4} c^{5} - 2 \, a^{3} b^{2} c^{3} d^{2} + a^{5} c d^{4} + {\left (a b^{4} c^{4} d - 2 \, a^{3} b^{2} c^{2} d^{3} + a^{5} d^{5}\right )} x\right )}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F(-1)] Timed out
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Timed out} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [B] Leaf count of result is larger than twice the leaf count of optimal. 285 vs.
\(2 (103) = 206\).
time = 1.65, size = 285, normalized size = 2.66 \begin {gather*} \frac {b^{2} c d \log \left ({\left | b^{2} - \frac {2 \, b^{2} c}{d x + c} + \frac {b^{2} c^{2}}{{\left (d x + c\right )}^{2}} - \frac {a^{2} d^{2}}{{\left (d x + c\right )}^{2}} \right |}\right )}{b^{4} c^{4} - 2 \, a^{2} b^{2} c^{2} d^{2} + a^{4} d^{4}} + \frac {d^{3}}{{\left (b^{2} c^{2} d^{2} - a^{2} d^{4}\right )} {\left (d x + c\right )}} - \frac {{\left (b^{4} c^{2} d^{2} + a^{2} b^{2} d^{4}\right )} \log \left (\frac {{\left | 2 \, b^{2} c d - \frac {2 \, b^{2} c^{2} d}{d x + c} + \frac {2 \, a^{2} d^{3}}{d x + c} - 2 \, d^{2} {\left | a \right |} {\left | b \right |} \right |}}{{\left | 2 \, b^{2} c d - \frac {2 \, b^{2} c^{2} d}{d x + c} + \frac {2 \, a^{2} d^{3}}{d x + c} + 2 \, d^{2} {\left | a \right |} {\left | b \right |} \right |}}\right )}{2 \, {\left (b^{4} c^{4} - 2 \, a^{2} b^{2} c^{2} d^{2} + a^{4} d^{4}\right )} d^{2} {\left | a \right |} {\left | b \right |}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 1.32, size = 147, normalized size = 1.37 \begin {gather*} \frac {b\,\ln \left (a+b\,x\right )}{2\,\left (a^3\,d^2-2\,a^2\,b\,c\,d+a\,b^2\,c^2\right )}-\frac {b\,\ln \left (a-b\,x\right )}{2\,\left (a^3\,d^2+2\,a^2\,b\,c\,d+a\,b^2\,c^2\right )}-\frac {d}{\left (a^2\,d^2-b^2\,c^2\right )\,\left (c+d\,x\right )}-\frac {2\,b^2\,c\,d\,\ln \left (c+d\,x\right )}{a^4\,d^4-2\,a^2\,b^2\,c^2\,d^2+b^4\,c^4} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________